<%-- 
    Document   : newjsp
    Created on : Apr 21, 2011, 2:07:05 PM
    Author     : DIT-0958372
--%>

<%@page import="java.util.ArrayList"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">

<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        <% ArrayList al = new ArrayList();
                    al.add("a");
                    al.add("b");
                    al.add("c");
                    pageContext.setAttribute("list", al);

        %>

        <table border="1">
            <tbody>
                <c:forEach items="<%= al%>" var="current" varstatus="status">
                    <tr>
                        <td><c:out value="${current}" /><td>
                        <td><c:out value="${status.count}"></td>
                         
                    </tr>
                </c:forEach>
            </tbody>
        </table>

    </body>
</html>
